

#ifndef CONFIGOPERATORIF_H
#define CONFIGOPERATORIF_H

#include "Entry/TExport.h"

namespace woe
{
	
	class TUTIL_API IConfigOperator
	{
	public:
		virtual ~IConfigOperator(){};

		/**    
		* Get(const std::string& key, int& nVal)
		* 
		* e.g.
		* int nVal;
		* Get("elem1.elem2.elem3", nVal);
		*
		* nVal will be 200
		*
		* return true if successfully get the value, else return false.
		*/

		virtual bool Get(const std::string& key, int& nVal) const = 0;

		/**    
		* Get(const std::string& key, float& fVal)
		* 
		* e.g.
		* float fVal;
		* Get("elem1.elem2.elem4", fVal);
		*
		* fVal will be 12.00000
		*
		* return true if successfully get the value, else return false.
		*/
		virtual bool Get(const std::string& key, float& fVal) const = 0;

		/**    
		* Get(const std::string& key, std::string& strVal)
		* 
		* e.g.
		* string strVal;
		* Get("elem1.elem2.property", strVal);
		*
		* strVal will be "information"
		*
		* return true if successfully get the value, else return false.
		*/
		virtual bool Get(const std::string& key, std::string& strVal) const = 0;


		/**    
		* Get(const std::string& key, int& nVal)
		* 
		* e.g.
		* int nVal;
		* Get("elem1.elem2.elem3", nVal);
		*
		* nVal will be 200
		*
		* return true if successfully get the value, else return false.
		*/

		virtual bool Set(const std::string& key, const int& nVal) = 0;

		/**    
		* Get(const std::string& key, float& fVal)
		* 
		* e.g.
		* float fVal;
		* Get("elem1.elem2.elem4", fVal);
		*
		* fVal will be 12.00000
		*
		* return true if successfully get the value, else return false.
		*/
		virtual bool Set(const std::string& key, const float& fVal) = 0;

		/**    
		* Set(const std::string& key, std::string& strVal)
		* 
		* e.g.
		* string strVal;
		* Get("elem1.elem2.property", strVal);
		*
		* strVal will be "information"
		*
		* return true if successfully get the value, else return false.
		*/
		virtual bool Set(const std::string& key, const std::string& strVal) = 0;


		/**    
		* Set(const std::string& key, std::string& strVal)
		* 
		* e.g.
		* string strVal;
		* Get("elem1.elem2.property", strVal);
		*
		* strVal will be "information"
		*
		* return true if successfully get the value, else return false.
		*/
		virtual bool GetNext(std::string& key, std::string& value) = 0;

	};
}

#endif // CONFIGOPERATORIF_H
